The present invention generally relates to semiconductor lasers, laser controllers, optical packages, and other optical systems incorporating semiconductor lasers. More specifically, the present invention relates to the use of deformable mirrors for focus compensation in optical packages that include, inter alia, a semiconductor laser and a second harmonic generation (SHG) crystal or another type of wavelength conversion device.